//
//  LTView.m
//  DongChiDaChiProject1
//
//  Created by lanou3g on 15/11/7.
//  Copyright © 2015年 com.lanou3g. All rights reserved.
//

#import "LTView.h"

@implementation LTView

// 重写父类的初始化方法
- (instancetype)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    if (self) {
        // 获取父视图的宽度和高
        CGFloat width = frame.size.width;
        CGFloat height = frame.size.height;
        // 初始化内部控件
        self.label = [[UILabel alloc] initWithFrame:CGRectMake(0, 0, width / 3, height)];
       // self.label.backgroundColor = [UIColor cyanColor];
        [self addSubview:self.label];
        
        
        self.textField = [[UITextField alloc] initWithFrame:CGRectMake(width / 3 + 20 * kWidthFitParameter, 0, width / 3 * 2 - 20 * kWidthFitParameter, height)];
       // self.textField.backgroundColor = [UIColor yellowColor];
        [self addSubview: self.textField];
        
    }
    return self;
}

@end
